<?php
/**
 * @package		Joomla.Site
 * @subpackage	mod_articles_latest
 * @copyright	Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
 * @license		GNU General Public License version 2 or later; see LICENSE.txt
 */

// no direct access
defined('_JEXEC') or die;
?>
			
<div class="w650 fl foods">
<?php if ($module->showtitle) { ?>
<h3><?php echo $module->title; ?></h3>
<?php } ?>	


<?php foreach ($list as $item) :  
$images = json_decode($item->images); 
?>
<div class="milk">
		<img src="<?php if ($images->image_intro=="") echo JURI::base()."/images/noimg.jpg";	else echo JURI::base().$images->image_intro; ?>" alt="<?php echo $item->title; ?>" title="<?php echo $item->title; ?>" />
		<p class="title"><a href="<?php echo $item->link; ?>"><?php echo $item->title; ?></a></p>
															<p class="intro"><?php						
															$words = explode(" ", strip_tags($item->introtext));
															if(count($words) > 13)
															{
																for($i=0;$i<=13;$i++)
																{
																	echo $words[$i]." ";
																}
																//echo "...";
															}
															else
															{
																echo strip_tags($item->introtext);
															}
															?></p>
</div>															
<?php endforeach; ?>
</div>